package ms;

import java.util.ArrayList;
import java.util.HashMap;
import java.util.Map;
import java.util.concurrent.ConcurrentHashMap;

public class test {
    public static void main(String[] args) {
//        Runnable task = () -> {
//            SingleObject instance = SingleObject.getInstance();
//            instance.showMessage();
//        };
//
//        // 创建并启动 10 个线程
//        for (int i = 0; i < 10000; i++) {
//            new Thread(task, "Thread-" + i).start();
//        }
//        ArrayList     list = new ArrayList();
        Map<String, String> map = new ConcurrentHashMap<>();
        map.put(null, "value");
        System.out.println(map.get(null));
      ThreadLocal<String> threadLocal = new ThreadLocal<>();
      threadLocal.set("value");
    }
}
